/*
** get_nbr.c for  in /u/all/caille_c/cu/public/colle
** 
** Made by carole cailleux
** Login   <caille_c@epitech.net>
** 
** Started on  Mon Apr 26 19:56:46 2010 carole cailleux
** Last update Mon Apr 26 19:58:26 2010 carole cailleux
*/

int		my_get_nbr(char *str)
{
  int		res;

  if (*str == '-')
    return (-my_get_nbr(str + 1));
  if (*str == '+')
    return (my_get_nbr(str + 1));
  res = 0;
  while (*str)
    {
      res = res * 10;
      res = res + *str - '0';
      str = str + 1;
    }
  return (res);
}
